<!-- $Id: admin_logs.htm 15477 2008-12-22 03:44:50Z sunxiaodong $ -->

{if $full_page}
{include file="pageheader.htm"}
{insert_scripts files="../js/utils.js,listtable.js"}
<script type="text/javascript" src="../js/calendar.php?lang={$cfg_lang}"></script>
<link href="../js/calendar/calendar.css" rel="stylesheet" type="text/css" />
<div class="form-div">
<table>
  <tr>
      <td>
      <form name="theForm" action="javascript:searchInfo()" >
      {$lang.view_admin}
      <select name="admin">
      <option value='0'>{$lang.select_admin}</option>
      {html_options options=$admin_list selected=$admin}
      </select>   
     
     日期<input type="text" name="add_time1" id="add_time1" class="input_te" readonly="readonly"   /><input name="selbtn1" type="button" id="selbtn1" onclick="return showCalendar('add_time1', '%Y-%m-%d %H:%M', '24', false, 'selbtn1');" value="{$lang.btn_select}" class="button"/>&nbsp;&nbsp;至&nbsp;&nbsp;<input type="text" name="add_time2" id="add_time2" class="input_te" readonly="readonly" /><input name="selbtn2" type="button" id="selbtn2" onclick="return showCalendar('add_time2', '%Y-%m-%d %H:%M', '24', false, 'selbtn2');" value="{$lang.btn_select}" class="button"/>
      {$lang.view_ip}
      <select name="ip">
      <option value='0'>{$lang.select_ip}</option>
      {html_options options=$ip_list selected=$ip}
      </select>
      <input type="submit" value="{$lang.comfrom}" class="button" />
      </form>
      </td>   
  </tr>
  <tr>
      <td colspan="3">
      <form name="Form2" action="admin_logs.php?act=batch_drop" method="POST">
      {$lang.drop_logs}
      <select name="log_date">
        <option value='0'>{$lang.select_date}</option>
        <option value='1'>{$lang.week_date}</option>
        <option value='2'>{$lang.month_date}</option>
        <option value='3'>{$lang.three_month}</option>
        <option value='4'>{$lang.six_month}</option>
        <option value='5'>{$lang.a_yaer}</option>
      </select>
      <input name="drop_type_date" type="submit" value="{$lang.comfrom}" class="button" />
      </form>
      </td>
    </tr>
</table>
</div>

<form method="POST" action="admin_logs.php?act=batch_drop" name="listForm">
<!-- start admin_logs list -->
<div class="list-div" id="listDiv">
{/if}

<table cellpadding="3" cellspacing="1">
  <tr>
    <th><input onclick='listTable.selectAll(this, "checkboxes")' type="checkbox">
    <a href="javascript:listTable.sort('log_id'); ">{$lang.log_id}</a>{$sort_log_id}</th>
    <th><a href="javascript:listTable.sort('user_id'); ">{$lang.user_id}</a>{$sort_user_id}</th>
    <th><a href="javascript:listTable.sort('log_time'); ">{$lang.log_time}</a>{$sort_log_time}</th>
    <th><a href="javascript:listTable.sort('ip_address'); ">{$lang.ip_address}</a>{$sort_ip_address}</th>
    <th>{$lang.log_info}</th>
  </tr>
  {foreach from=$log_list item=list}
  <tr>
    <td width="10%"><span><input name="checkboxes[]" type="checkbox" value="{$list.log_id}" />{$list.log_id}</span></td>
    <td width="15%" class="first-cell"><span>{$list.user_name|escape:html}</span></td>
    <td width="20%" align="center"><span>{$list.log_time}</span></td>
    <td width="15%" align="left"><span>{$list.ip_address}</span></td>
    <td width="40%" align="left"><span>{$list.log_info}</span></td>
  </tr>
  {/foreach}
  <tr>
    <td colspan="2"><input name="drop_type_id" type="submit" id="btnSubmit" value="{$lang.drop_logs}" disabled="true" class="button" /></td>
    <td align="right" nowrap="true" colspan="10">{include file="page.htm"}</td>
  </tr>
</table>

{if $full_page}
</div>
<!-- end ad_position list -->

<script type="text/javascript" language="JavaScript">
  listTable.recordCount = {$record_count};
  listTable.pageCount = {$page_count};

  {foreach from=$filter item=item key=key}
  listTable.filter.{$key} = '{$item}';
  {/foreach}
  {literal}
  onload = function()
  {
    // &#65533;&#65533;&#700;&#65533;&#65533;鹜&#65533;&#65533;
    startCheckOrder();
  }
  {/literal}


function searchInfo()
{
    listTable.filter['user_id'] = Utils.trim(document.forms['theForm'].elements['admin'].value);
	listTable.filter.add_time1 = Utils.trim(document.forms['theForm'].elements['add_time1'].value);
	listTable.filter.add_time2 = Utils.trim(document.forms['theForm'].elements['add_time2'].value);
    listTable.filter['ip'] = Utils.trim(document.forms['theForm'].elements['ip'].value);
	listTable.filter['page'] = 1;
    listTable.loadList();
}
</script>
{include file="pagefooter.htm"}
{/if}
